package cn.wolfcode.crm.query;

import cn.wolfcode.crm.util.StringUtil;
import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

@Setter
@Getter
public class AttendanceQueryObject extends QueryObject {
    private String keyword;
    private String deptName;

    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date beginDate;

    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date endDate;

    public String getKeyword() {

        return StringUtil.empty2Null(keyword);
    }

    public String getDeptName() {

        return StringUtil.empty2Null(deptName);
    }

}
